package com.ax.associator.store.dao;

import com.ax.associator.store.domain.PrescriptionAudit;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;

import java.util.List;
import java.util.Map;

@Mapper
public interface PrescriptionAuditMapper {
    int deleteByPrimaryKey(Long prescriptionAuditId);

    int insert(PrescriptionAudit record);

    int insertSelective(PrescriptionAudit record);

	/**
	 * 会员处方审核记录
	 * @param associatorId
	 * @return
	 */
    List<PrescriptionAudit> queryAuditRecord(@Param("associatorId") Long associatorId);

	/**
	 * 药师服务次数
	 * @param pharmacistId
	 * @return
	 */
    Integer queryPharmacistServiceNo(@Param("pharmacistId") Long pharmacistId);

    int updateByPrimaryKey(PrescriptionAudit record);
    
    /**
	 * 查看处方审核详情(或全部)
	 * 
	 * @param Map<String, Object> map
	 *           
	 * @return List<PrescriptionAudit>
	 */
    List<PrescriptionAudit> queryPrescriptionAuditingMapper(Map<String, Object> map);

    /**
	 * 分页记数
	 *
	 * @param Map<String, Object> map
	 *
	 * @return Integer
	 */
    Integer count(Map<String, Object> map);
}